<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;
use EloquentFilter\Filterable;
use App\Models\Traits\Admin\ActionButtonTrait;
use Illuminate\Support\Facades\Storage;


class MerchantDetails extends Model
{
    //
    use Filterable, ActionButtonTrait;

    protected $append = ['merchantdetails'];
    /**
     * The attributes that are mass assignable.
     *
     * @var array
     */
    protected $actions = ['edit','delete'];
    protected $actionUri = 'merchantdetails';

   
    protected $fillable = [
        'merchant_name', 'merchant_address', 'telephone','wechat', 'merchant_id',
    ];
    //

     //模型关联
    public function merchant()
    {
        return $this->belongsTo(Merchant::class, 'merchant_id', 'id');
    }

}
